package com.wxx.ws.pojo;

import lombok.Data;

/**
 * 用来封装服务端给浏览器发送的消息数据
 */
@Data
public class ResultMessage {

    private boolean isSystem;

    private String fromName;

    private Object message; //如果是系统消息  则是数组

    public ResultMessage(){

    }

    public ResultMessage(boolean isSystem, String fromName, Object message) {
        this.isSystem = isSystem;
        this.fromName = fromName;
        this.message = message;
    }

    @Override
    public String toString() {
        return "ResultMessage{" +
                "isSystem=" + isSystem +
                ", fromName='" + fromName + '\'' +
                ", message=" + message +
                '}';
    }

}
